<h1><?= strtotitle(__('guests')) ?></h1>
<p>
    <?= $this->Html->link("+" . __('new') . " " . __('guest'), '/guests/create') ?> |
    <?= $this->Html->link(strtotitle(__('events')), '/events') ?> |
    <?= $this->Html->link(__('Repertoire'), '/repertoire') ?>
</p>

<? if(count($guests)): ?>
<table>
	<tr>
		<th><?= __('name') ?></th>
		<th width="1%"></th>
	</tr>
	<? foreach($guests as $guest): ?>
	<tr>
		<td><?= $this->Html->link($guest['Guest']['firstname'] . " " . $guest['Guest']['surname'], array('action' => 'edit', $guest['Guest']['id'])) ?></td>		
		<td>
			<?= $this->Html->link(__('delete'), array('action'=>'delete', $guest['Guest']['id']), array(
		        'confirm' => __("Do you want to delete guest?")
			)) ?>
		</td>
	</tr>
	<? endforeach; ?>
</table>
<?= $this->element("pagination", array(
	"total" => $total,
	"page" => $page
)) ?>
<? else: ?>
<p><?= __('no records') ?>.</p>
<? endif; ?>